<%@ Page Language="C#" EnableViewState="false" ValidateRequest="false" AutoEventWireup="true" 
	MasterPageFile="~/App_ThemeMasters/NoStyle/OneColumnLayout.Master" Inherits="Syrinx.Gui.AspNet.Ajax.NitobiBasePage" EnableEventValidation="false" %>

<%@ Register Assembly="Swaf.Gui.AspNet2" Namespace="Swaf.Gui.AspNet2" TagPrefix="swf" %>
<%@ Register Assembly="ScsAspNet" Namespace="Syrinx.Gui.AspNet.Ajax" TagPrefix="saj" %><%@ Register Assembly="NitobiControls" Namespace="Nitobi" TagPrefix="ntb" %>
<%@ Register Assembly="ScsAspNet" Namespace="Articles.Gui.AspNet" TagPrefix="art" %>

<!--#include file="~/SiteControls/RegisterStandardControls.txt"-->
<!--#include file="../SiteControls/StandardHeaderPageContent.inc"-->
<!--#include file="../SiteControls/StandardFooterPageContent.inc"-->

<asp:Content ID="c1" ContentPlaceHolderID="title" runat="server">
	<swf:BizProc ID="pArt1" runat="server" factoryName="eComProducts">
		<State EditModeSessionKey="GlobalEdit" />
		<ParentBizProc id="loginBP" />
	</swf:BizProc>
	<swf:BizProc ID="prodTax" runat="server" factoryName="eComProductTaxes" >
		<ParentBizProc id="pArt1" fieldName="id" dataId="pid" />
	</swf:BizProc>
	<swf:BizProc id="orderItemBP" runat="server" FactoryName="eComSalesOrderItems">
		<State baseListFieldNameforMaster="product" includeSelf="true" />
		<ParentBizProc id="orderBP" fieldName="id" dataId="pid" />
		<ParentBizProc id="pArt1" fieldName="id" dataId="id" />
		<ParentBizProc id="pArt1" fieldName="id" dataId="mlpid" />
	</swf:BizProc>
	<swf:BizProc runat="server" id="t" FactoryName="articleTrail">
		<ParentBizProc id="pArt1" fieldName="id" dataId="pid" />
	</swf:BizProc>
</asp:Content>

<asp:Content ID="c2" ContentPlaceHolderID="trails" runat="server">
<div class="px11">
		<art:ArticleParentTrail runat="server" ID="ArticleParentTrail1" 
			ParentBizProcIds="t" 
			ReadOnlyTemplate="Articles.Gui.AspNet.ArticleParentTrail-Simple">
			<macros>
				<Entry name="navLink" type="String">/articles/$id$.aspx</Entry>
			</macros>
		</art:ArticleParentTrail>
</div>
		<div class="clearer"></div>
	    <br style="line-height:5px" />
		<div  >
			<span class="button4"><saj:ActionButton runat="server" ID="ActionButton1" Actions="pArt1.SwitchEdit" Text="Edit" SessionBoolSwitch="GlobalEdit"  /></span>
			<span class="button1"><saj:ActionButton runat="server" ID="ActionButton2" Actions="pArt1.SwitchTranslation" Text="Translate" SessionBoolSwitch="TranslationMode" /></span>
			<span class="button1"><saj:ActionButton runat="server" ID="ActionButton12" Actions="pArt1.TranslateArticle" Text="Auto Translate" /></span>
			<span class="button1"><saj:ActionButton runat="server" ID="ActionButton3" Actions="pArt1.AddBizObj" Text="Add" /></span>
			<span class="button6"><saj:ActionButton runat="server" ID="ActionButton4" Actions="pArt1.UpdateBizObj" Text="Update" /></span>
			<span class="button1"><saj:ActionButton runat="server" ID="ActionButton5" Actions="pArt1.CancelEdits" Text="Cancel" /></span>
			<span class="button5"><saj:ActionButton runat="server" ID="ActionButton6" Actions="pArt1.DeleteBizObj" Text="Delete" ClientClick="if(!confirm('Are you sure you want to delete?'))return false;"/></span>
			<span class="button1"><saj:ActionButton runat="server" ID="ActionButton7" Actions="pArt1.SetArticlePicture" Text="Set Image" ToolTip="Set primary media for this article" 
				PopupPage="../popups/SetArticleImagePopup.aspx" PopupHeight="535px" PopupWidth="800px" PopupTitle="Select a primary image for this article." /></span>
			<span class="button1"><saj:ActionButton runat="server" ID="ActionButton8" Actions="pArt1.GenerateFromMedia" Text="Generate" ToolTip="Generate child article from media derictory"
				PopupPage="../popups/ImageArticleGenPopup.aspx" PopupHeight="535px" PopupWidth="800px" PopupTitle="Generate articles from media directory."/></span>
			<span class="button1"><saj:ActionButton runat="server" ID="ActionButton9" Actions="pArt1.GenerateFromYouTube" Text="uTubeGen" ToolTip="Generate child article from You Tube Account"
				PopupPage="../popups/PopupYouTubeGenPopup.aspx" PopupHeight="535px" PopupWidth="800px" PopupTitle="Generate articles from You Tube Account." /></span>
			<span class="button3"><saj:ActionButton runat="server" ID="ActionButton10" Actions="pArt1.MovePrev" Text="Previous" /></span>
			<span class="button3"><saj:ActionButton runat="server" ID="ActionButton11" Actions="pArt1.MoveNext" Text="Next" /></span>
		</div>
<div class="clearer"></div>
</asp:Content>

<asp:Content ID="c3" ContentPlaceHolderID="mainContent" runat="server">
	    <saj:NitobiBizObjDisplay ID="NitobiBizObjDisplay2" runat="server" 
		    ReadOnlyTemplate="eCom.Gui.AspNet.ProductRODisplay$suggestedDisplayType$,eCom.Gui.AspNet.ProductDetailsROView" 
		    EditableTemplate="eCom.Gui.AspNet.ProductRWDisplay,eCom.Gui.AspNet.ProductDetailsRWView" 
		    ParentBizProcIds="pArt1" >
			    <macros>
				    <Entry name="navLink" type="String">../std/ArticleView.aspx?gArt1pid=$pid$&amp;gArt1id=$id$</Entry>
				    <Entry name="imageRes" type="String">Thumbnail</Entry>
			    </macros>
	    </saj:NitobiBizObjDisplay>
		<saj:ComplexBizObjListDisplay ID="pt1" runat="server" ParentBizProcIds="prodTax"
			ReadOnlyTemplate=""
			EditableTemplate="eCom.Gui.AspNet.ProductTaxListDisplay"  >
		</saj:ComplexBizObjListDisplay>		

		<saj:NitobiBizObjDisplay ID="pt2" runat="server"
			ReadOnlyTemplate="eCom.Gui.AspNet.SalesOrderItemSimpleDisplay"
			ParentBizProcIds="orderItemBP">
			<macros Parent="orderItemBP" />
			</saj:NitobiBizObjDisplay>
</asp:Content>
